/**
 * 
 */
package com.lehecai.core.lottery;

import java.util.ArrayList;
import java.util.List;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.lehecai.core.IntegerBeanLabelItem;

/**
 * @author qatang
 * 支付宝上传临时日志状态
 */
public class WithdrawUploadLogStatus extends IntegerBeanLabelItem {

	private static final long serialVersionUID = 9133836199922834854L;

	private static final Logger logger = LoggerFactory.getLogger(WithdrawUploadLogStatus.class.getName());
	
	private static List<WithdrawUploadLogStatus> items = new ArrayList<WithdrawUploadLogStatus>();
	private static List<WithdrawUploadLogStatus> queryItems = new ArrayList<WithdrawUploadLogStatus>();
	
	protected WithdrawUploadLogStatus(String name, int value, boolean queryOnly) {
		super(WithdrawUploadLogStatus.class.getName(), name, value);
		
		queryItems.add(this);
		if (!queryOnly) {
			items.add(this);
		}
	}
	protected WithdrawUploadLogStatus(String name, int value) {
		this(name, value, false);
	}
	
	public static WithdrawUploadLogStatus getItem(int value){
		try {
			return (WithdrawUploadLogStatus)WithdrawUploadLogStatus.getResult(WithdrawUploadLogStatus.class.getName(), value);
		} catch (Exception e) {
			logger.error(e.getMessage(), e);
			return null;
		}
	}
	
	public static List<WithdrawUploadLogStatus> getItems() {
		return items;
	}
	public static List<WithdrawUploadLogStatus> getItemsForQuery() {
		return queryItems;
	}
	
	public static final WithdrawUploadLogStatus ALL = new WithdrawUploadLogStatus("全部", -1 ,true);
	//public static final PhaseStatus DEFAULT = new PhaseStatus("默认", 0);
	
	public static final WithdrawUploadLogStatus UNUPLOAD = new WithdrawUploadLogStatus("未上传", 1);
	public static final WithdrawUploadLogStatus UPLOADED = new WithdrawUploadLogStatus("已上传", 2);
	public static final WithdrawUploadLogStatus MANUAL = new WithdrawUploadLogStatus("人工处理", 3);
	public static final WithdrawUploadLogStatus HANDLED = new WithdrawUploadLogStatus("已处理", 4);
}
